//recordCount = 20;
//show = 20
//pageShow = 11;
//pageCount = 100;
//pageNow = 86;
//pageStr = "?page=_page_";
//document.write(showListPage(recordCount, show, pageCount, pageNow, pageStr));
function showListPage(recordCount, show, pageShow, pageCount, pageNow, pageStr){
		if(pageCount<1) pageCount =0;
		if(pageNow<1) pageNow = 0;
		str = '共 <B>'+recordCount+'</B> 条记录，当前 <B>'+pageNow+'/'+pageCount+'</B> 页 ';
		if(pageCount<=pageShow){
				startHave = false;
				endHave = false;
				startNum = 1;
				endNum = pageCount;
		} else if(pageNow-1 <= pageShow/2){
				startHave = false;
				endHave = true;
				startNum = 1;
				endNum = pageShow-1;
		} else if(pageCount-pageNow <= pageShow/2){
				startHave = true;
				endHave = false;
				startNum = pageCount - pageShow + 2;
				endNum = pageCount;
		} else {
				startHave = true;
				endHave = true;
				startNum = pageNow - Math.floor((pageShow-2)/2);
				endNum = startNum + pageShow - 3;
		}
		if(startHave){
				startStr = " [<A class=\"negative\" href='"+pageStr.replace("_page_",1)+"'>1</A>]... ";
				str += startStr;
		}
		for(i=startNum; i<=endNum; i++){
				if(pageNow==i)
				str += "[" + i + "]";
				else
				str += " [<A class=\"negative\" href='" + pageStr.replace("_page_",i) + "'>" + i + "</A>] ";
		}
		if(endHave){
				endStr = " ...[<A class=\"negative\" href='" + pageStr.replace("_page_",pageCount) + "'>" + pageCount + "</A>] ";
				str += endStr;
		}
		return str;
}